package com.example.novelstory.service.dxy;


import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.example.novelstory.dao.dxy.CategoryDao2;
import com.example.novelstory.entity.Category2;
import java.util.List;
import org.springframework.stereotype.Service;

@Service
public class CategroyServicelmpl2 extends ServiceImpl<CategoryDao2,Category2> {
//    @Autowired
//    CategoryDao2 categoryDao2;
//
//    @Override
    public List<Category2> findcategoryAll2() {
//        List<Category2> all = categoryDao2.findcategoryAll2();
        return list();
    }
//
//    @Override
    public List findcategoryid(Category2 category2) {
//        int usercategoryInfo2 = categoryDao2.findcategoryid(classification);
//        if (usercategoryInfo2 == 1) {
//            List<Category2> all = categoryDao2.findcategoryAll2();
//            return all;
//        } else {
        QueryWrapper queryWrapper=new QueryWrapper<>();
        queryWrapper.eq("classification",category2.getClassification());
            return list(queryWrapper);

        }

    }
//}
